<?php
/**
 * Created by PhpStorm.
 * User: wzy12
 * Date: 2018/10/12
 * Time: 15:56
 */

namespace app\admin\validate;


use think\Validate;

class Article extends Validate
{
    protected $rule = [
        'cat_id' => 'require',
        'title|文章名称'  =>  'require',
        'desc|文章描述' =>  'require',
        '__token__' => 'token|require'
    ];

    protected $message = [
        '__token__.require'  =>  '请不要进行非法操作',
        'cat_id.require' => '请选择分类',
    ];
    protected $scene = [
        'del' => ['__token__'],
        'status' => ['is_show' => 'require|number'],
    ];

}